package com.example.demo.mapper;

import com.example.demo.entity.dto.ApiSuiteTreeDto;
import com.example.demo.entity.ApiSuite;
import org.apache.ibatis.annotations.Param;

import java.util.List;

public interface ApiSuiteMapper {
    int insertApiSuite(ApiSuite apiSuite);

    int updateApiSuite(ApiSuite apiSuite);

    int deleteById(@Param(value = "apiSuiteId") Integer apiSuiteId);

    List<ApiSuite> findAll();

    List<ApiSuite> findByProjectId(@Param(value = "projectId") Integer projectId);

    List<ApiSuiteTreeDto> findTreeByProjectId(@Param(value = "projectId") Integer projectId);

    List<ApiSuite> findAllByName(@Param(value = "apiSuiteName") String apiSuiteName);

    List<ApiSuite> findAllByBP(@Param(value = "apiSuiteName") String apiSuiteName,@Param(value = "projectId") Integer projectId);

    ApiSuite findAllById(@Param(value = "apiSuiteId") Integer apiSuiteId);
}
